<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:ui="http://java.sun.com/jsf/facelets">
	
	<h:head id="head">
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<link rel="shortcut icon" href="/favicon.ico" type="image/favicon" />
		<title>User Sign Up</title>
	</h:head>
	
	<h:body id="body">
		
		<h:form>
			<h:outputText value="Please fill in the form to sign up."/>
			<br />
		
			<h:panelGrid columns="2">
				<h:outputText value="Username"/>
				<h:inputText id="username" value="#{user.username}">
					 <f:ajax /> 
				</h:inputText>
				<h:outputText value="Name"/>
				<h:inputText id="name" value="#{user.name}">
					 <f:ajax /> 
				</h:inputText>
				<h:outputText value="Surname"/>
				<h:inputText id="surname" value="#{user.surname}">
					 <f:ajax /> 
				</h:inputText>
				<h:outputText value="E Mail"/>
				<h:inputText id="email" value="#{user.email}">
					 <f:ajax /> 
				</h:inputText>
				<h:outputText value="Date of Birth"/>
				<h:inputText id="birthDate" value="#{user.birthDate}">
					 <f:ajax /> 
				</h:inputText>
				<h:outputText value="Gender"/>
				<h:inputText id="gender" value="#{user.gender}">
					 <f:ajax /> 
				</h:inputText>
			</h:panelGrid>
			
			<h:commandButton value="Sign Up" type="submit" action="#{user.createNewUser}">
					 <f:ajax render="output"/> 
			</h:commandButton>
			<br />
			
			<h:outputText id="output" value="#{user.users}"/>
		</h:form>
		
	</h:body>
</html>